<?php
	include("library/vars.php");
	include("library/config.php");
	include("library/opendb.php");
	
	$query="DELETE FROM shows WHERE show_nicename='$show'";
	mysql_query($query);
	
	$query="DELETE FROM seasons WHERE show_ID='$show'";
	mysql_query($query);
	
	$query="DELETE FROM episodes WHERE show_ID='$show'";
	mysql_query($query) or die('Error, query failed');
	
	include 'library/closedb.php';
	header( 'Location: index.php?m=show_deleted' );
?>